package jtk.project4.fleet.field;

//import java.awt.TextField;

import jtk.project4.fleet.domain.AddPayment;
import nl.coderight.jazz.form.FormField;
import nl.coderight.jazz.form.FormLayout;
import nl.coderight.jazz.form.control.GroupControl;
import nl.coderight.jazz.form.field.NumberField;
import nl.coderight.jazz.form.field.SelectField;
import nl.coderight.jazz.form.field.TextField;
import nl.coderight.jazz.form.field.button.PushButton;
import nl.coderight.jazz.form.field.button.RadioButton;

public class PaymentMethodField extends GroupControl<AddPayment>{
	private SelectField c1Field;
	private SelectField c2Field;
	private TextField b2Field;
	private NumberField b1Field;
	private TextField b3Field;
	private TextField b4Field;
	private TextField b5Field;
	

public PaymentMethodField(String bindID) {
	setTitle("Payment Method");
	setBindID(bindID);
	createFields();
	createLayout();
}

private void createFields() {	
	b1Field = new NumberField("check", 20);
	b2Field = new TextField("credit", 20);
	b3Field = new TextField ("name", 20);
	b4Field = new TextField ("transaction", 20);
	b5Field = new TextField ("other", 20);
	
	c1Field = new SelectField("expiration", "20");
	c2Field = new SelectField("year","20");
	
}

private void createLayout() {
	setLayout(new FormLayout())
	.addLabel("Check #: ") .addField(b1Field)
	.addRow()
	.addLabel("Credit Card #: ") .addField(b2Field)
	.addRow()
	.addLabel("Name On Card: ") .addField(b3Field)
	.addRow()
	.addLabel("Expiration Mo: ") .addField(c1Field) .addLabel("Year: ") .addField(c2Field)
	.addRow()
	.addLabel("Transaction #: ") .addField(b4Field)
	.addRow()
	.addLabel("Electronic Transfer")
	.addRow()
	.addLabel("Other: ") .addField(b5Field)
	.addRow();
}

}
